ListPopupWindow

constructor(@NonNull context: @NonNull Context)(source)

Create a new, empty popup window capable of displaying items from a ListAdapter. Backgrounds should be set using setBackgroundDrawable.

Parameters

context

Context used for contained views.


constructor(@NonNull context: @NonNull Context, @Nullable attrs: @Nullable AttributeSet)(source)

Create a new, empty popup window capable of displaying items from a ListAdapter. Backgrounds should be set using setBackgroundDrawable.

Parameters

context

Context used for contained views.

attrs

Attributes from inflating parent views used to style the popup.


constructor(@NonNull context: @NonNull Context, @Nullable attrs: @Nullable AttributeSet, @AttrRes defStyleAttr: Int)(source)

Create a new, empty popup window capable of displaying items from a ListAdapter. Backgrounds should be set using setBackgroundDrawable.

Parameters

context

Context used for contained views.

attrs

Attributes from inflating parent views used to style the popup.

defStyleAttr

Default style attribute to use for popup content.


constructor(@NonNull context: @NonNull Context, @Nullable attrs: @Nullable AttributeSet, @AttrRes defStyleAttr: Int, @StyleRes defStyleRes: Int)(source)

Create a new, empty popup window capable of displaying items from a ListAdapter. Backgrounds should be set using setBackgroundDrawable.

Parameters

context

Context used for contained views.

attrs

Attributes from inflating parent views used to style the popup.

defStyleAttr

Style attribute to read for default styling of popup content.

defStyleRes

Style resource ID to use for default styling of popup content.